package com.ssy.lingxi.contract.esign.token;

/**
 * 锁接口
 * @author yzc
 * @version 2.0.0
 * @date 2021/7/15
 */
public interface EsignLock {

    String TOKEN_LOCK_KEY = "esign_token_lock";

    /**
     * 加锁
     * @param key 锁key
     * @return 锁对象
     */
    Object lock(String key);

    /**
     * 释放锁
     * @param obj 锁对象
     * @return true陈宫, false失败
     */
    boolean releaseLock(Object obj);
}